// @ts-ignore
/* eslint-disable */

/**
 * 该文件为 @umijs/openapi 插件自动生成，请勿随意修改。如需修改请通过配置 openapi.config.ts 进行定制化。
 * */

import { request, type RequestOptions } from '@/utils/request';

export async function classPage (
  params: API.ClassesPageParams,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/student/classes/page', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: params,
    ...(options || {}),
  });
}

// class list
export async function classList (
  params: API.ClassesPageParams,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/student/classes/list', {
    method: 'GET',
    params: {
      ...params,
    },
   ...(options || {}),
  });
}

// course page
export async function coursePage (
  params: API.CoursePageParams,
  options?: RequestOptions,
) {
  return request<API.CourseItem>('/course/page', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: params,
   ...(options || {}),
  });
}

// course page
export async function courseList (
  params: API.CoursePageParams,
  options?: RequestOptions,
) {
  return request<API.CourseItem>('/course/list', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: params,
   ...(options || {}),
  });
}

// student list
export async function studentList (
  params: API.ClassesPageParams,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/student/list', {
    method: 'POST',
    data: params,
   ...(options || {}),
  });
}

// course update
export async function courseUpdate (
  params: API.CourseItem,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/course/update', {
    method: 'POST',
    data: params,
   ...(options || {}),
  });
}

// course create
export async function courseCreate (
  params: API.CourseItem,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/course/create', {
    method: 'POST',
    data: params,
  ...(options || {}),
  });
}

// classCreate
export async function classCreate (
  params: API.ClassesItem,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/student/classes/create', {
    method: 'POST',
    data: params,
  ...(options || {}),
  });
}

// classUpdate
export async function classUpdate (
  params: API.ClassesItem,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/student/classes/update', {
    method: 'POST',
    data: params,
 ...(options || {}),
  });
}

// courseLocationUpdate
export async function courseLocationUpdate (
  params: API.CourseItem,
  options?: RequestOptions,
) {
  return request<API.ClassesItem>('/course/location/update', {
    method: 'POST',
    data: params,
 ...(options || {}),
  });
}

